package com.zz.inventory.service.impl;

import com.ruoyi.system.api.domain.SysDept;
import com.zz.inventory.mapper.SysDeptMapper;
import com.zz.inventory.service.ISysDeptService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

@Service
public class SysDeptServiceImpl implements ISysDeptService {
    @Autowired
    private SysDeptMapper deptMapper;

    @Override
    public SysDept selectDeptByNameAndParentId(String deptName, Long parentId) {
        return deptMapper.selectDeptByNameAndParentId(deptName, parentId);
    }

    @Override
    public int insertDept(SysDept dept) {
        return deptMapper.insertDept(dept);
    }

    @Override
    public int updateDept(SysDept dept) {
        return deptMapper.updateDept(dept);
    }
}